----------------------------------------------------------------------------------------------
      name:  <unnamed>
       log:  C:\ado\personal\Directed dyad examples.log
  log type:  text
 opened on:   5 Jan 2012, 11:06:19

. do "C:\ado\personal\Directed dyad examples.do"

. clear all

. use "Directed Dyad example file.dta", replace

. 
. 
. * Create directed dyad contagion spatial lag variable with (undirected) contiguity variable 
> of form ik*jm as connectivity variable
. * Note: ik*jm means that for other dyads to matter, both countries k and m must be contiguou
> s to both i and j (complementary contiguity)
. * The created spatial effect variable has no values for country_i=="Japan" since Japan has n
> o contiguous neighbor in this dataset
. spdir  patentsfiled, weight(contig_or_less1000km) source(country_i) target(country_j) time(y
> ear) link(ik*jm) sename(SL_dir_W_contig_compl) filename(SL_dir_W_contig_compl)



Checking version of mmerge.ado.
c:\ado\stbplus\m\mmerge.ado
*! 2.5.0  26feb2002

User needs to have mmerge.ado version 2.5.0 or higher installed.

If not, type net install mmerge, from(http://fmwww.bc.edu/RePEc/bocode/m) force  into editor t
> o install.



User has specified that:

   patentsfiled is the variable to be spatially lagged.

   country_i is the identifying variable of source unit i.

   country_j is the identifying variable of target unit j.

   contig_or_less1000km will represent the product of two links:

      link of source unit i to source units k and link of target unit j to target units m.

   year is the numeric time variable.

   the spatial effect is to be row-standardized.

If these assumptions are incorrect, the generated spatial effect variable will be incorrect.

The created spatial effect variable will be automatically merged into the original dataset.

   Warning: variable SL_dir_W_contig_compl will be dropped from dataset before merging, if alr
> eady existant.

   Warning: file SL_dir_W_contig_compl will be replaced in current working directory, if alrea
> dy existant.


*** Check the above. ***  --  Press q to break, press any other button to continue.

Generating spatial effect components for dyads involving 20 source units in total - please wai
> t.
..........
..........


Combining spatial effect components for dyads involving 20 source units in total - please wait
> .
..........
..........


Appending spatial effects for 19 times in total - please wait.
.........
..........


File SL_dir_W_contig_compl
  with variables country_i, country_j, year
  and SE variable SL_dir_W_contig_compl saved in current working directory


Spatial lag variable SL_dir_W_contig_compl merged into the original dataset.

. 
. * As above, but (undirected) contiguity variable of form ik+jm as connectivity variable (sub
> stitutable contiguity)
. * Note: ik+jm means that for other dyads to matter, it is sufficient if either country k or 
> m is contiguous to i or j
. spdir  patentsfiled, weight(contig_or_less1000km) source(country_i) target(country_j) time(y
> ear) link(ik+jm) sename(SL_dir_W_contig_subst) filename(SL_dir_W_contig_subst)



Checking version of mmerge.ado.
c:\ado\stbplus\m\mmerge.ado
*! 2.5.0  26feb2002

User needs to have mmerge.ado version 2.5.0 or higher installed.

If not, type net install mmerge, from(http://fmwww.bc.edu/RePEc/bocode/m) force  into editor t
> o install.



User has specified that:

   patentsfiled is the variable to be spatially lagged.

   country_i is the identifying variable of source unit i.

   country_j is the identifying variable of target unit j.

   contig_or_less1000km will represent the sum of two links:

      link of source unit i to source units k and link of target unit j to target units m.

   year is the numeric time variable.

   the spatial effect is to be row-standardized.

If these assumptions are incorrect, the generated spatial effect variable will be incorrect.

The created spatial effect variable will be automatically merged into the original dataset.

   Warning: variable SL_dir_W_contig_subst will be dropped from dataset before merging, if alr
> eady existant.

   Warning: file SL_dir_W_contig_subst will be replaced in current working directory, if alrea
> dy existant.


*** Check the above. ***  --  Press q to break, press any other button to continue.

Generating spatial effect components for dyads involving 20 source units in total - please wai
> t.
..........
..........


Combining spatial effect components for dyads involving 20 source units in total - please wait
> .
..........
..........


Appending spatial effects for 19 times in total - please wait.
.........
..........


File SL_dir_W_contig_subst
  with variables country_i, country_j, year
  and SE variable SL_dir_W_contig_subst saved in current working directory


Spatial lag variable SL_dir_W_contig_subst merged into the original dataset.

. 
. 
. * As above, but excluding dyads that contain either i or j from exerting a spatial effect
. spdir  patentsfiled, weight(contig_or_less1000km) source(country_i) target(country_j) time(y
> ear) link(ik+jm) exclusive sename(SL_direxcl_W_contig_subst) filename(SL_direxcl_W_contig_su
> bst)



Checking version of mmerge.ado.
c:\ado\stbplus\m\mmerge.ado
*! 2.5.0  26feb2002

User needs to have mmerge.ado version 2.5.0 or higher installed.

If not, type net install mmerge, from(http://fmwww.bc.edu/RePEc/bocode/m) force  into editor t
> o install.



User has specified that:

   patentsfiled is the variable to be spatially lagged.

   country_i is the identifying variable of source unit i.

   country_j is the identifying variable of target unit j.

   contig_or_less1000km will represent the sum of two links:

      link of source unit i to source units k and link of target unit j to target units m.

   year is the numeric time variable.

   Dyads containing either i or j as either source or target are excluded from having a spatia
> l effect on dyad ij.

   the spatial effect is to be row-standardized.

If these assumptions are incorrect, the generated spatial effect variable will be incorrect.

The created spatial effect variable will be automatically merged into the original dataset.

   Warning: variable SL_direxcl_W_contig_subst will be dropped from dataset before merging, if
>  already existant.

   Warning: file SL_direxcl_W_contig_subst will be replaced in current working directory, if a
> lready existant.


*** Check the above. ***  --  Press q to break, press any other button to continue.

Generating spatial effect components for dyads involving 20 source units in total - please wai
> t.
..........
..........


Combining spatial effect components for dyads involving 20 source units in total - please wait
> .
..........
..........


Appending spatial effects for 19 times in total - please wait.
.........
..........


File SL_direxcl_W_contig_subst
  with variables country_i, country_j, year
  and SE variable SL_direxcl_W_contig_subst saved in current working directory


Spatial lag variable SL_direxcl_W_contig_subst merged into the original dataset.

. 
. * Create directed dyad contagion spatial lag variable with directed exports from i to k as c
> onnectivity variable (exports from i to j are automatically transformed)
. spdir  patentsfiled, weight(exports_i_to_j) source(country_i) target(country_j) time(year) l
> ink(ik) sename(SL_dir_W_exports_i_to_k) filename(SL_dir_W_exports_i_to_k)



Checking version of mmerge.ado.
c:\ado\stbplus\m\mmerge.ado
*! 2.5.0  26feb2002

User needs to have mmerge.ado version 2.5.0 or higher installed.

If not, type net install mmerge, from(http://fmwww.bc.edu/RePEc/bocode/m) force  into editor t
> o install.



User has specified that:

   patentsfiled is the variable to be spatially lagged.

   country_i is the identifying variable of source unit i.

   country_j is the identifying variable of target unit j.

   exports_i_to_j will link source unit i to source units k.

   year is the numeric time variable.

   the spatial effect is to be row-standardized.

If these assumptions are incorrect, the generated spatial effect variable will be incorrect.

The created spatial effect variable will be automatically merged into the original dataset.

   Warning: variable SL_dir_W_exports_i_to_k will be dropped from dataset before merging, if a
> lready existant.

   Warning: file SL_dir_W_exports_i_to_k will be replaced in current working directory, if alr
> eady existant.


*** Check the above. ***  --  Press q to break, press any other button to continue.

Generating spatial effect components for dyads involving 20 source units in total - please wai
> t.
..........
..........


Combining spatial effect components for dyads involving 20 source units in total - please wait
> .
..........
..........


Appending spatial effects for 19 times in total - please wait.
.........
..........


File SL_dir_W_exports_i_to_k
  with variables country_i, country_j, year
  and SE variable SL_dir_W_exports_i_to_k saved in current working directory


Spatial lag variable SL_dir_W_exports_i_to_k merged into the original dataset.

. 
. 
. * Create directed dyad contagion spatial lag variable with directed exports from k to i as c
> onnectivity variable (exports from i to j are automatically transformed)
. spdir  patentsfiled, weight(exports_i_to_j) source(country_i) target(country_j) time(year) l
> ink(ki) sename(SL_dir_W_exports_k_to_i) filename(SL_dir_W_exports_k_to_i) 



Checking version of mmerge.ado.
c:\ado\stbplus\m\mmerge.ado
*! 2.5.0  26feb2002

User needs to have mmerge.ado version 2.5.0 or higher installed.

If not, type net install mmerge, from(http://fmwww.bc.edu/RePEc/bocode/m) force  into editor t
> o install.



User has specified that:

   patentsfiled is the variable to be spatially lagged.

   country_i is the identifying variable of source unit i.

   country_j is the identifying variable of target unit j.

   exports_i_to_j will link source units k to source unit i.

   year is the numeric time variable.

   the spatial effect is to be row-standardized.

If these assumptions are incorrect, the generated spatial effect variable will be incorrect.

The created spatial effect variable will be automatically merged into the original dataset.

   Warning: variable SL_dir_W_exports_k_to_i will be dropped from dataset before merging, if a
> lready existant.

   Warning: file SL_dir_W_exports_k_to_i will be replaced in current working directory, if alr
> eady existant.


*** Check the above. ***  --  Press q to break, press any other button to continue.

Generating spatial effect components for dyads involving 20 source units in total - please wai
> t.
..........
..........


Combining spatial effect components for dyads involving 20 source units in total - please wait
> .
..........
..........


Appending spatial effects for 19 times in total - please wait.
.........
..........


File SL_dir_W_exports_k_to_i
  with variables country_i, country_j, year
  and SE variable SL_dir_W_exports_k_to_i saved in current working directory


Spatial lag variable SL_dir_W_exports_k_to_i merged into the original dataset.

. 
. 
. 
end of do-file

. log close
      name:  <unnamed>
       log:  C:\ado\personal\Directed dyad examples.log
  log type:  text
 closed on:   5 Jan 2012, 11:07:24
----------------------------------------------------------------------------------------------
